File systems of various types, commonly organized as trees of directories or folders, are used by millions of users every day to store and access data in various types of computing environments. Some file systems may be implemented using local storage devices and computational resources of a single computer server, while other file systems may be distributed among numerous servers and storage devices, with user read and write requests being handled via network messages. In some provider network environments, for example, tens of thousands of clients of a distributed file storage service may potentially be granted access to one or more file systems, with the data and metadata of the file systems being spread among numerous devices at one or more data centers to support desired levels of performance, availability and data durability.
Many traditional file systems were designed for relatively low levels of concurrency compared to the concurrency that may have to be supported in today's cloud-based computing infrastructures. As the expected number of concurrent file system users has increased, various optimizations (such as partitioning file data across numerous storage devices, caching file data, and so on) have been implemented to improve the file I/O (input/output) responsiveness and file I/O bandwidths. However, at least in some file system implementations, operations such as directory moves may still involve the acquisition of file-system-wide locks. The use of a file-system-wide lock guarantees that no more than one such operation can proceed at a time within a given file system, independently of the depth and width of the directory tree of the file system, and independently of the number of users of the file system. While the lock is held on behalf of one user's directory move request, changes to the file system's directory tree by any other user are prevented, and it therefore becomes easier to detect and prevent illegal directory moves such as the equivalent of “mv /a /a/b/c/d” which might lead to loops within the tree. While such restrictions on concurrent directory moves may be reasonable for small-scale or single-server file systems, they may not be quite as acceptable in environments in which thousands of users distributed around the world share access to a large distributed file system. Different users may store their files in completely disjoint sub-trees of the file system's directory tree, for example, and may wish to be permitted to reorganize their sub-tree structure without the kinds of delays that may result from the use of a single file-system-wide lock.
While embodiments are described herein by way of example for several embodiments and illustrative drawings, those skilled in the art will recognize that embodiments are not limited to the embodiments or drawings described. It should be understood, that the drawings and detailed description thereto are not intended to limit embodiments to the particular form disclosed, but on the contrary, the intention is to cover all modifications, equivalents and alternatives falling within the spirit and scope as defined by the appended claims. The headings used herein are for organizational purposes only and are not meant to be used to limit the scope of the description or the claims. As used throughout this application, the word “may” is used in a permissive sense (i.e., meaning having the potential to), rather than the mandatory sense (i.e., meaning must). Similarly, the words “include,” “including,” and “includes” mean including, but not limited to.